package forum.client;

import com.google.gwt.user.client.ui.Panel;
import com.google.gwt.user.client.ui.VerticalPanel;

/**
 * A singleton access to mainPanel widget.
 * Purpose: avoid passing the mainPannel for class to class.
 * 
 * @author Mirsky
 * 
 */
public class MainPanel {
	private static VerticalPanel mainPanel = null;
	
	public static Panel get() {
		if (mainPanel == null) {
			mainPanel = new VerticalPanel();
			mainPanel.addStyleName("mainPanel");
		}
		
		return mainPanel;
	}

}
